From 489816c39adf728d8a54201ce600948d05ed9f4d Mon Sep 17 00:00:00 2001 From: Alessandro Bono Date: Mon, 29 Jun 2026 13:16:55 +0200 Subject: [PATCH] shell/global: Plug a leak Use g_autoptr to ensure the variant is always freed. Part-of: (cherry picked from commit 2405521d039fa61f754c190b6f3fd5a0b7f8c2da) --- src/shell-global.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/shell-global.c b/src/shell-global.c index dc4075e26..443376f77 100644 --- a/src/shell-global.c +++ b/src/shell-global.c @@ -148,7 +148,7 @@ got_switcheroo_control_gpus_property_cb (GObject *source_object, { ShellGlobal *global; GError *error = NULL; - GVariant *gpus; + g_autoptr (GVariant) gpus = NULL; gpus = g_dbus_connection_call_finish (G_DBUS_CONNECTION (source_object), res, &error); -- 2.39.5